# -*- codeing = utf-8 -*-
# @Time : 2020/9/7 13:20
# @Author : 阳某
# @File : excel.py
# @Software : PyCharm


import openpyxl  # 读写xlsx文件

from openpyxl import Workbook
from openpyxl import load_workbook
# wb = Workbook()
# wa =wb.active
# wa.append(['ids,xingming'])
# line = ['1','bobo']
# wa.append(line)         #逐行添加
# wb.save('./result.xlsx')

# wb = Workbook()  # 新建表格
# wb.save(filename="")  # 保存表格
# wb = load_workbook()  # 打开已有表格
# ws = wb.active  # 选取当前表格活跃的sheet
# ws.wb[]  # 根据sheetname打开sheet
# ws = wb.creat_sheet(title='')  # 新建一个sheet
# ws.cell(row=1, column=1).value = ''  # 往ws这个sheet第一行第一列写入
# ws.max_column  # 获取最大列数
# ws.cell(row=1, column=1).value  # 获取第一行第一列的值
# ws['A1'].column  # 获取该数据列数

# 获取最大行数
# wb = load_workbook('丝路学院0 - 副本.xlsx')
# sheet = wb[wb.sheetnames[0]]
# max_row = sheet.max_row
# print(max_row)


import xlrd  # 读取xls文件
import xlwt  # 写xls文件
